{% load static %}
<!DOCTYPE html>
<html>
<head>
  <meta charset="utf-8">
  <meta http-equiv="X-UA-Compatible" content="IE=edge">
  <title>超市进销存管理系统 | 登录</title>
  <meta name="viewport" content="width=device-width, initial-scale=1">
  <link rel="stylesheet" href="{% static 'plugins/fontawesome-free/css/all.min.css' %}">
  <link rel="stylesheet" href="{% static 'plugins/icheck-bootstrap/icheck-bootstrap.min.css' %}">
  <link rel="stylesheet" href="{% static 'dist/css/adminlte.min.css' %}">
  <link rel="stylesheet" href="{% static 'plugins/sweetalert2-theme-bootstrap-4/bootstrap-4.min.css' %}">
</head>
<body class="hold-transition login-page">
<div class="login-box">
  <div class="login-logo">
    <a href="#"><b>超市进销存管理系统</b></a>
  </div>
  <div class="card">
    <div class="card-body login-card-body">
      <p class="login-box-msg">帐户登录</p>
      <form method="post" id="userForm">
        {% csrf_token %}
        <div class="input-group mb-3">
          {{ form.username }}
          <div class="input-group-append">
            <div class="input-group-text">
              <span class="fas fa-envelope"></span>
            </div>
          </div>
        </div>
        <div class="input-group mb-3">
          {{ form.password }}
          <div class="input-group-append">
            <div class="input-group-text">
              <span class="fas fa-lock"></span>
            </div>
          </div>
        </div>
        <div class="row">
          <div class="col-12">
            <button type="submit" class="btn btn-primary btn-block">登录</button>
          </div>
        </div>
      </form>
      {% if messages %}
        {% for message in messages %}
          <div class="alert alert-danger mt-2">{{ message }}</div>
        {% endfor %}
      {% endif %}
    </div>
  </div>
</div>
<script src="{% static 'plugins/jquery/jquery.min.js' %}"></script>
<script src="{% static 'plugins/bootstrap/js/bootstrap.bundle.min.js' %}"></script>
<script src="{% static 'plugins/sweetalert2/sweetalert2.min.js' %}"></script>
<script src="{% static 'plugins/jquery-validation/jquery.validate.min.js' %}"></script>
<script src="{% static 'plugins/jquery-validation/additional-methods.min.js' %}"></script>
<script src="{% static 'dist/js/adminlte.min.js' %}"></script>
<script src="{% static 'dist/js/login.js' %}"></script>
</body>
</html>
